export const menuTypeOptions = [
    {value: 'DIR', text: '目录'},
    {value: 'MODULE', text: '模块'},
    {value: 'BUTTON', text: '按钮'},
    {value: 'API', text: '接口'}
];

export const menuOpenTypeOptions = [
    {value: 'DEFAULT', text: '默认'},
    {value: 'IFRAME', text: 'iframe'},
    {value: 'TAB', text: '新窗口'}
];

export const httpRequestMethodOptions = [
    {value: 'GET'},
    {value: 'POST'},
    {value: 'PUT'},
    {value: 'DELETE'},
    {value: 'PUT'},
    {value: 'PATCH'},
    {value: 'OPTIONS'},
    {value: 'HEAD'},
    {value: 'TRACE'}
];



export const menuTypeMap = {
    DIR: 'success',
    MODULE: 'danger',
    BUTTON: 'info',
    API: 'warning'
};


export const menuTypeKeyValue = menuTypeOptions.reduce((acc, cur) => {
    acc[cur.value] = cur.text;
    return acc
}, {});
